package com.ikangtai.shecare.common.util;

import android.app.Activity;
import android.content.Context;
import android.content.pm.PackageManager;

/**
 * Created by ikangtai on 2016/6/17.
 */
public class SelfPermissionUtil {
    private static final String CAMERA_PERMISSION = "android.permission.CAMERA";
    public static boolean checkCameraPermission(Context context){
        int perm = context.checkCallingOrSelfPermission(CAMERA_PERMISSION);
        return perm == PackageManager.PERMISSION_GRANTED;
    }
}
